##Commercial Parking Description: In this version, we laid out the data without customizing its features. We consider this the worst map of our iterations, because it fails to provide a hierarchy of information. The only data that is isolated are the pink dots. However, it is impossible to know what the elements describe without a legend.

parking_plot <- ggplot(commercialparking) +
  geom_sf(shape = 20, color = "#CC0066", size = 3)
parking_plot +
  geom_sf(data = meters) +
  geom_sf(data = openspace)

#changing symbology

parking_plot <- ggplot(commercialparking) +
  geom_sf(shape = 20, color = "blue", size = 4)
parking_plot +
  geom_sf(data = meters, color = "darkorange") +
  geom_sf(data = openspace, fill = "forestgreen", color = NA)

#changing symbology again

ggplot() +
  
ggtitle("Cambridge Park(ing)") +
  
#BASE MAP
    annotation_map_tile(
    zoomin = 0, 
    progress = "none", 
    type = "cartolight") +
    geom_sf() +
    labs(caption = "Map tiles and data by OpenStreetMap") +
  
#DATA 
   geom_sf(
    data = openspace, 
    color = NA, 
    aes(fill = "Open Space")
    ) +
  geom_sf(
    data = meters, 
    fill = "darkorange",
    aes(color = "Parking Meters")
    ) +
  geom_sf(
    data = commercialparking, 
    shape = 20, 
    size = 3, 
    fill = NA,
    aes(color = "Commercial Parking")
    ) +
  
  scale_color_manual(values = c("blue", "darkorange"), name = "") +
  scale_fill_manual(values = "forestgreen", name = "") +
  
  theme_void()

#changing symbology again

ggplot() +
  
ggtitle("Cambridge Park(ing)") +
  
#BASE MAP
    annotation_map_tile(
    zoomin = 0, 
    progress = "none", 
    type = "cartodark") +
    geom_sf() +
    labs(caption = "Map tiles and data by OpenStreetMap") +
  
#DATA 
   geom_sf(
    data = openspace, 
    color = NA, 
    aes(fill = "Open Space")
    ) +
  geom_sf(
    data = meters, 
    fill = NA,
    aes(color = "Parking Meters")
    ) +
  geom_sf(
    data = commercialparking, 
    shape = 20, 
    size = 3, 
    aes(color = "Commercial Parking")
    ) +
  scale_color_manual(values = c("deeppink", "darkviolet"), name = "") +
  scale_fill_manual(values = "chartreuse", name = "") +
  
  theme_void()

#changing symbology again

ggplot() +
  
ggtitle("Cambridge Park(ing)") +
  
#BASE MAP
    annotation_map_tile(
    zoomin = 0, 
    progress = "none", 
    type = "cartolight") +
    geom_sf() +
    labs(caption = "Map tiles and data by OpenStreetMap") +
  
#DATA 
   geom_sf(
    data = openspace, 
    color = NA, 
    alpha = 0.5,
    aes(fill = "Open Space")
    ) +
  geom_sf(
    data = meters, 
    fill = NA,
    shape = NA,
    aes(color = "Parking Meters")
    ) +
  geom_sf(
    data = commercialparking, 
    shape = 3, 
    size = 3, 
    fill = NA,
    aes(color = "Commercial Parking")
    ) +
  
  scale_color_manual(values = c("brown1", "brown3"), name = "") +
  scale_fill_manual(values = "forestgreen", name = "") +
  
  theme_void()

ggplot()+
 #TITLE + AXIS LABELS
        #TITLE
        ggtitle("CAMBRIDGE PARKING IN RELATION TO OPEN SPACE") +
        theme(
          plot.title = element_text(
            color="black", 
            size=10, 
            face="bold", #FONT FACE OPTIONS = PLAIN, BOLD, BOLD.ITALIC, ITALIC
            vjust = 5,
            hjust = .5))+
            theme(plot.margin = unit(c(1.5,1.5,1.5,1.5), "cm"))+
  
        #X AXIS
#        xlab("LONGITUDE") +
#        theme(
#          axis.title.x = element_text(
#            size=7,
#            vjust = -2.5)) +
  
        #Y  AXIS
#        ylab("LATITUDE")+
#        theme(
#          axis.title.y = element_text(
#            size=7,
#            vjust = 5)) +
  
  #FORMAT TEXT + LABELS
     easy_center_title()+
     easy_move_legend("right")+
     easy_x_axis_labels_size(7)+
     easy_y_axis_labels_size(7)+

  #BASE MAP
      annotation_map_tile(
        zoomin = 0, 
        progress = "none", 
        type = "cartolight") +
  
  #DATA
      #commercial parking
        geom_sf(
        data = commercialparking, 
        aes(fill="Commercial Parking Lots"), 
        alpha = .7, 
        color = "aquamarine"
        ) +
      #metered parking
      geom_sf(
        data = meters, 
        color = "black", 
        aes(fill="Metered Parking")
        ) +
      #open space
      geom_sf(
        data = openspace, 
        aes(fill="Parks"), 
        alpha = 0.25, 
        color = "tan",
        ) +
  
  #APPEARANCE
      #themes
      scale_fill_manual(values = c("aquamarine", "black", "tan"), name = "") +
      scale_color_manual(values = c("aquamarine", "black", "tan"), name = "") +
  
      #add a scale
      annotation_scale(
        pad_x = unit(8, "cm"),
        pad_y = unit(.5, "cm"),
        line_width = .125,
        height = unit(0.125, "cm"),
        text_pad = unit(0.15, "cm"),
        text_cex = 0.7,
        tick_height = 0.4) + 
  
      #add an arrow
      annotation_north_arrow(
        pad_x = unit(7, "cm"),
        pad_y = unit(.25, "cm"),
        height = unit(0.5, "cm"),
        width = unit(0.5, "cm"),
        
        #north arrow style
        style = north_arrow_orienteering(
          text_size = 1
          ))